/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.rafkind.raytracer;

/**
 *
 * @author drafkind
 */
public class Light {
  private Vector3 position;
  private Vector3 color;

  public Light() {
  }

  public Vector3 getPosition() {
    return position;
  }

  public void setPosition(Vector3 position) {
    this.position = position;
  }

  public Vector3 getColor() {
    return color;
  }

  public void setColor(Vector3 color) {
    this.color = color;
  }

  public Vector3 getColorAt(Vector3 where) {
    double d = position.getDistanceTo(where);
    return color.times(1.0/(d*d));
  }
}
